//
//  HelpVC.m
//  Project
//
//  Created by 冯东辉 on 2018/10/16.
//  Copyright © 2018年 FengDongHui. All rights reserved.
//

#import "HelpVC.h"

@interface HelpVC ()

@property (nonatomic, strong) UIWebView *webView;

@end

@implementation HelpVC

- (void)viewDidLoad {
    
    [super viewDidLoad];
    
    self.navTitleL.text = @"帮助";
    [self createBlueNavigationBar:YES];
    
    [self creatWebView];
}

- (void)didReceiveMemoryWarning {
    
    [super didReceiveMemoryWarning];
}

- (void)creatWebView {
    
    self.webView = [[UIWebView alloc] initWithFrame:CGRectMake(0, SafeAreaTopHeight, GET_SCREEN_WIDTH(), GET_SCREEN_HEIGHT()-SafeAreaTopHeight)];
    
    self.webView.backgroundColor = UICOLOR_HEX(0xffEDEEEF);
    
    self.webView.scalesPageToFit = YES;
    
    NSString *path = [[NSBundle mainBundle] pathForResource:@"湖南移动质量掌上通操作手册v1.1.docx" ofType:nil];
    NSString *encodedComponent = [path stringByAddingPercentEncodingWithAllowedCharacters:[NSCharacterSet URLQueryAllowedCharacterSet]];
    
    NSURL *fileUrl = [[NSURL alloc] initWithString:encodedComponent];
    
    NSURLRequest *request = [NSURLRequest requestWithURL:fileUrl];
    
    [self.webView loadRequest:request];
    
    [self.view addSubview:self.webView];
}


@end
